ListBox.ColumnSortDirection

Used to get or set the sort direction for the passed column, according to the following class constants. The first column is numbered zero.
SortDescending (-1): Descending
SortNone (0): Don't sort
SortAscending (1): Ascending (default)
For example:
lb1.ColumnSortDirection(2)=ListBox.SortDescending
ColumnSortDirection doesn't actually sort the rows; it only establishes the sort direction that is used when the Sort method is called.

Syntax

ColumnSortDirection( columnNumber ) as Integer


Parameters

columnNumber

Integer


Notes

The sort direction can be set even if there is no header for the ListBox.

If you set ColumnSortDirection to Don't Sort, the user can't sort the column by clicking its header. Don't Sort will block the usual calls to the SortColumn and CompareRows events.